s = input().split(" ")
kwh = int(s[0])
x = float(s[1])
over = 0 if kwh < 50 else kwh-50
result = kwh*.53+over*x
print(f"cost = {result:.2f}")